package com.hfi.anemicVsdomain.ddd;

import lombok.AllArgsConstructor;
import lombok.Data;

/**
 * 值对象
 * @author ChangLiang
 * @date 2020/5/18
 */
@Data
@AllArgsConstructor
public class Product {

    private String name;

    private RecognitionStrategy strategy;

    public void calculateRecognitions(Contract contract) {
        strategy.calculateRevenueRecognition(contract);
    }
}
